package cn.peach.pet.mapper;

import cn.peach.basic.mapper.BaseMapper;
import cn.peach.pet.domain.Pet;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface PetMapper extends BaseMapper<Pet> {

    Pet loadByIdDetail(Long id);

    /**
     *  批量查询上架的宠物列表
     */
    List<Pet> patchSelectById(@Param("ids") List<Long> ids, @Param("stateOnline") Integer stateOnline);

    Pet selectByIdAndState(@Param("id") Long id, @Param("stateOnline") Integer stateOnline);

    void updateOnsaleById(@Param("ids") List<Long> ids, @Param("saletime") String saletime, @Param("state") Integer state);

}
